Gradation corrections of the brightness signal of an image have been carried out to improve the visibility of subjects (people, animals, vehicles, road signs, or the like) in images that have been taken in foggy, hazy, or rainy weather and have a narrow brightness signal distribution. When gradation corrections are performed, if a part of the image having a narrow brightness distribution includes a portion with extremely high brightness or extremely low brightness, the gradation correction of the image with the narrow brightness distribution is inadequate. A known countermeasure is to convert brightnesses in the input image data that are equal to or greater than a given brightness on the high brightness side to the maximum brightness, convert brightnesses equal to or less than a given brightness on the low brightness side to the minimum brightness, and stretch intermediate brightnesses linearly from the minimum brightness to the maximum brightness according to their brightness values (see, for example, Patent Reference 1).